home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
United Public Domain Gold 2
/
United Public Domain Gold 2.iso
/
utilities
/
pu478.dms
/
pu478.adf
/
BlockMem
/
blockmem.doc
< prev
next >
Wrap
Text File
|
1993-09-02
|
4KB
|
140 lines
BlockMem 1.0 / SmartBlock 1.0 - © Neall Verheyde / 1993 Pyxis Software
What it is
----------
Blockmem is a small utility which takes two memory addresses, and
allocates all of the memory between them, preventing the system (and OS
friendly programs) from using that area of memory.
SmartBlock is a program very similar to blockmem. It performs exactly the
same operation, but is not restricted to contigious memory chunks (ie, it
"looks" for unused memory within the specified address, and allocates
around memory which is already used). If the memory is already used, you
can be fairly certain that it's not faulty.
Why???
------
If you have bad memory in your computer, and can't get it fixed
immediately, it's much better to simply block the memory off from the OS,
rather than hoping that a program won't try and grab it for itself and
cause the system to blow up.
How to use it
-------------
Simple! Just add the hexidecimal addresses of the beginning and end of
the memory you want to block off, ie:
1> BLOCKMEM 200000 400000
Would disable two megabytes of memory from $200000 to $400000 (in my
case, fast memory). Note that if ANY memory in the specified range is
already in use, the program will return an error, and not allocate
anything. Error checking is also performed to ensure that all memory
addresses are legal. A good way to determine where the bad addresses
are is to use some sort of memory testing utility. We use the program
that comes with MicroBotics memory boards for this purpose.
You can disable any sort of memory you wish, anywhere in the system,
providing it's free.
Using SmartBlock is much the same, simply type:
1> SMARTBLOCK 0 200000
Would block all unused CHIP memory (if you happen to have a machine with
2mb chip), and leave the portions in use untouched.
A debug mode is also available in SmartBlock which can (if you so wish)
see what the program is allocating and how much success it's having.
Simply run the program with a "debug" switch on the command line:
1> SMARTBLOCK 0 200000 DEBUG
Which will produce the following results:
-----
Debug mode.
3: mc_start=341d48 mc_end=600000 mc_size=2876088 alloc_start=400000
alloc_size=65536
Allocated 65536 bytes.
-----
Of course the main output line is all on a single line, however we don't
have wide enough screens to see that do we :-). The basic information that
this gives you is fairly simple though.
mc_start The beginning of a free memory block (within supplied
address arguments)
mc_end The end of the free memory block
mc_size The size of the memory block
alloc_start The beginning address of the block of memory which is to
be allocated (within the free memory in the previous
arguments)
alloc_size The size of the memory block allocated
Note that you might get a "failed" parameter at the end of a line if the
system failed to allocate a block of memory. Also, you will get a debug
line for each memory block within the addresses you specify, so if you have
memory fragmented into a few thousand blocks, you might be waiting a
while...
How to get rid of it
--------------------
Reboot! Sorry, at this time there's no other way of returning the
memory to the system. It would be possible to simply deallocate the
memory, but since this program was written to lock out bad memory,
returning the bad memory wasn't a high priority.
Ye Olde Legal Disclaimer (abbreviated)
-------------------------------------
We're not responsible for anything that anyone does with any of our
software. 'Nuff said. This software is fully distributable of course,
enjoy!
Pyxis Software is:
------------------
Neall Verheyde verheyde@sfu.ca
- Computer Science
Simon Fraser University
British Columbia, Canada
David Griffiths dgriff@unixg.ubc.ca
- Television Broadcasting
British Columbia Institute of Technology
British Columbia, Canada
Other Pyxis Utilities:
----------------------
ClockTweek - Helps correct periodic errors in the system clock.
Purge2.0 - Deletes files in a way that they are "unrecoverable".
MemWatch - Helps find program memory loss.
NetUtils - ParNet/SerNet chat, and remote reboot.
ReqInter - Reqtools.library interface for HiSoft BASIC.